﻿// -----------------------------------------------------------------------
// <copyright file="Equipment_BLL.cs" company="">
// TODO: Update copyright text.
// </copyright>
// -----------------------------------------------------------------------

namespace PMSGSC.BLL
{
    using System;
    using System.Collections.Generic;
    using System.Linq;
    using System.Text;
    using PMSGSC.DAL;

    /// <summary>
    /// TODO: Update summary.
    /// </summary>
    public class Equipment_BLL
    {
        public static List<Equipment> GetAll(int shipID)
        {
            return Equipment_DAL.GetAll(shipID);
        }
        public static Equipment GetDataByName(string name)
        {
            return Equipment_DAL.GetDataByName(name);
        }
        public static List<Equipment> GetCounterTypeEquipment(int id)
        {
            return Equipment_DAL.GetCounterTypeEquipment(id);
        }
     
        public static bool Insert(Equipment equipment)
        {
            return Equipment_DAL.Insert(equipment);
        }
        public static List<Equipment> GetDataByParentID(int id)
        {
            return Equipment_DAL.GetDataByParentId(id);
        }
        public static Equipment GetDataById(int id)
        {
            return Equipment_DAL.GetDataById(id);
        }
        public static bool Update(Equipment equipment)
        {
            return Equipment_DAL.Update(equipment);
        }
        public static bool Delete(Equipment equipment)
        {
            return Equipment_DAL.Delete(equipment);
        }
        public static bool TestBeforeDeleteComponentFinal(int id)
        {
            return Equipment_DAL.TestBeforeDeleteComponentFinal(id);
        }
        public static bool IsExits(Equipment equipment)
        {
            return Equipment_DAL.IsExits(equipment);
        }
        public static int GetLastEquipmentID()
        {
            return Equipment_DAL.GetLastEquipmentID();
        }
        public static Equipment GetDataByNumber(string number)
        {
            return Equipment_DAL.GetDataByNumber(number);
        }
        public static bool UpdateCounter(Equipment equip)
        {
            return Equipment_DAL.UpdateCounter(equip);
        }
        public static List<Equipment> SearchEquipment(Equipment equip, int ShipID)
        {
            return Equipment_DAL.SearchEquipment(equip, ShipID);
        }
        public static List<Equipment> PrintStatusOfEquipment(string From, string To, string Name, int StatusID, int ShipID)
        {
            return Equipment_DAL.PrintStatusOfEquipment(From, To, Name, StatusID, ShipID);
        }
    }
}
